package com.sdp.wz.db.wz_inventory_detail.entity;

import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableField;
import java.io.Serializable;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 
 * </p>
 *
 * @author zsp
 * @since 2024-07-29
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("wz_inventory_detail")
public class WzInventoryDetail extends Model<WzInventoryDetail> {

    private static final long serialVersionUID=1L;

    /**
     * 内码
     */
    @TableId("key_id")
    private String keyId;

    /**
     * 外键
     */
    @TableField("inventory_id")
    private String inventoryId;

    /**
     * 器材编号
     */
    @TableField("wz_no")
    private String wzNo;

    /**
     * 器材名称
     */
    @TableField("wz_name")
    private String wzName;

    /**
     * 账面库存
     */
    @TableField("now_num")
    private BigDecimal nowNum;

    /**
     * 实际库存
     */
    @TableField("real_num")
    private BigDecimal realNum;

    /**
     * 结果
     */
    @TableField("inventory_res")
    private String inventoryRes;

    /**
     * 盘盈盘亏状态
     */
    @TableField("inventory_state")
    private String inventoryState;

    /**
     * 差值
     */
    @TableField("inventory_dif")
    private BigDecimal inventoryDif;

    /**
     * 所属公司
     */
    @TableField("org_no")
    private String orgNo;


    @Override
    protected Serializable pkVal() {
        return this.keyId;
    }

}
